<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<style type="text/css">
			#times{
				width: 300px;
				height: 300px;
				background-image: url(img/16.jpg);
				background-repeat: no-repeat;
				font-size: 12px;
				text-align: center;
				line-height: 325px;
			}
		</style>
	</head>
	<body>
		<div id="times"></div>
		<script type="text/javascript">
			var times=document.getElementById("times")
			function sz(){
				t=setInterval(
				function(){
				//获取时间对象
				var dd=new Date;
				//获取年月日，时分秒
				var y=dd.getFullYear();
				var m=dd.getMonth()+1;
				var d=dd.getDate();
				var h=dd.getHours();
				var i=dd.getMinutes();
				var s=dd.getSeconds();
				var wkday = dd.getDay();
				times.innerHTML=y+"年"+m+"月"+d+"日"+"   "+h+":"+i+":"+s+" "+"星期"+"日一二三四五六".charAt(wkday);
			},1000)
		}
			sz()
		</script>
		<!-- <script type="text/javascript">
			// setInterval(task,1000);//每隔1000毫秒(一秒)执行一次task
			// function task(){
			// 	var now = new Date();
			// 	document.write("now");
			// }
		</script> -->
	</body>
</html>
